#define _CRT_SECURE_NO_WARNINGS
#include "process.h"

char style[C_NUM] = { '+', '-', '#', '/', '*' };

void process()
{
       int cnt = 0;
       char bar[NUM];
       memset(bar, '\0', sizeof(bar));
       const char* table = "|\\-/|\\-/";
       while (cnt <= 100) {
            printf("[%-100s][%d%%][%c]\r", bar, cnt, table[cnt % 8]);
             fflush(stdout);
             bar[cnt++] = style[N];
             usleep(50000);
        
    }
       printf("\n");
}
